
  <div class="row RowSpace" style="margin-bottom:20px;">
    <div class="LableDiv" style="width:50px;"><Btn class="BtnSave" value="保存" ng-click="btnSave()"></Btn></div>
    <div class="LableDiv" style="width:60px;"><Btn value="放弃" ng-click="btnCancel()"></Btn></div>
    <div class="LableDiv" style="width:50px;"><Btn class="BtnAdd" value="新增" ng-click="btnAdd()"></Btn></div>
    <div class="LableDiv" style="width:60px;"><Btn class="BtnDelete" value="删除" ng-click="btnDelete()"></Btn></div>
    <div class="LableDiv" style="width:50px;">
      <BtnFind DisplayName="查找" WindowTitle="用户" change="btnFindChange()" module="Module.User">
        <Column type="0" width="100px" displayname="用户名" valuefield="Code"></Column>
        <Column type="textbox" width="80px" displayname="名称" valuefield="Name"></Column>
        <Column type="textbox" width="200px" displayname="部门" valuefield="Department.Name"></Column>
        <Column type="textbox" width="200px" DisplayName="邮箱" valuefield="Email"></Column>
      </BtnFind>
    </div>
    <div class="LableDiv" style="width:60px;"><Btn value="列表" ng-click="btnList()"></Btn></div>
    <div class="LableDiv" style="width:50px;"><Btn value="首页" ng-click="btnFirstPage()"></Btn></div>
    <div class="LableDiv" style="width:50px;"><Btn value="上页" ng-click="btnPrePage()"></Btn></div>
    <div class="LableDiv" style="width:50px;"><Btn value="下页" ng-click="btnNextPage()"></Btn></div>
    <div class="LableDiv" style="width:50px;"><Btn value="末页" ng-click="btnLastPage()"></Btn></div>
  </div>
  <div class="row RowSpace">
    <div class="LableDiv"><Label>用户名</Label></div>
    <div class="InputDiv"><TextBox value="Module.User.FocusedRecord.Code" isempty="false"></TextBox></div>
    <div class="LableDiv"><Label>名称</Label></div>
    <div class="InputDiv"><TextBox value="Module.User.FocusedRecord.Name"></TextBox></div>
    <div class="LableDiv"><Label>芯片</Label></div>
    <div class="InputDiv" style="width:42%;"><TextBox Enabled="false" value="Module.User.FocusedRecord.UniqueID"></TextBox></div>
  </div>
  <div class="row RowSpace">
    <div class="LableDiv"><Label>部门</Label></div>
    <div class="InputDiv" style="width:42%;">
      <Refer EntityName="Department" WindowTitle="部门" key="Module.User.FocusedRecord.Department._id" value="Module.User.FocusedRecord.Department.Code" text="Module.User.FocusedRecord.Department.Name" ValueField="Code" TextField="Name">
        <Column type="0" width="100px" displayname="编码" valuefield="Code"></Column>
        <Column type="textbox" width="100px" displayname="名称" valuefield="Name"></Column>
        <Column width="286px" displayname="备注" valuefield="Remark"></Column>
      </Refer>
    </div>
    <div class="LableDiv"><Label>邮箱</Label></div>
    <div class="InputDiv"><TextBox value="Module.User.FocusedRecord.Email"></TextBox></div>
    <div class="LableDiv"><Label>电话</Label></div>
    <div class="InputDiv"><TextBox value="Module.User.FocusedRecord.Phone"></TextBox></div>
  </div>
  <div class="row RowSpace">
    <div class="LableDiv"><Label>备注</Label></div>
    <div class="InputDiv" style="width:42%;height:80px;"><TextareaBox value="Module.User.FocusedRecord.Remark"></TextareaBox></div>
    <div class="LableDiv"><Label>头像</Label></div>
    <div class="InputDiv" style="height:80px;">
      <img ng-src="{{Module.User.FocusedRecord.Image?Module.User.FocusedRecord.Image:'users/img/default.png'}}" style="width: 80px;height:80px;border-radius:50%;margin-left:5px;cursor: pointer;"
      ng-click="openAvatar()">
    </div>
    <div class="LableDiv"><Label>生效</Label></div>
    <div class="InputDiv"><CheckBox value="Module.User.FocusedRecord.IsEffective"></CheckBox></div>
  </div>
  
  <div class="row RowSpace" style="margin-top:20px;color:#68BDE2;font-weight:bold;">
    角色分配
  </div>

  <div class="row RowSpace">
    <DataGrid module="Module._Role" height="275px">
      <ReferColumn EntityName="Role" beforeshow="refBeforeShow(refScope)" DisplayName="角色" width="200px" WindowTitle="角色" KeyField="RoleId" ValueField="RoleCode" TextField="RoleName" BindKeyField="_id" BindValueField="Code" BindTextField="Name">
        <Column type="0" width="100px" DisplayName="编码" valuefield="Code"></Column>
        <Column type="textbox" width="100px" DisplayName="名称" valuefield="Name"></Column>
      </ReferColumn>
    </DataGrid>
  </div>
